import org.junit.Test;

import java.io.BufferedWriter;
import java.io.File;
import java.io.FileWriter;
import java.io.IOException;

/*
 *@auther:yangzihe @洋纸盒
 *@discription:
 *@create 2024-12-05 17:12
 */
public class test02 {
    public static void main(String[] args) throws IOException {
        String[] lines = {"第一行内容","第二行内容","第三行内容"};
        File redofile = new File("C:\\Users\\yangz\\Desktop\\金工实习\\数据库实用技术\\log\\redo.txt");
        BufferedWriter bw = new BufferedWriter(new FileWriter(redofile));
        bw.write("1234");
        bw.newLine();
        for(String line : lines)
        {
            bw.write(line);
            bw.newLine();

        }
        bw.write("end");
        bw.close();


    }
}
